import {
    GETMOVIELISE
} from '../constnant/movieConst' //引入type常量

//初始值
const init = {
    movieList: []
}

export default function movieReducer(prevStata = init, action) {
    const {
        type,
        data
    } = action;

    switch (type) {
        case GETMOVIELISE:
            return {
                ...prevStata, movieList: data
            }
    }

    return prevStata
}